Class("PropertyGrid",
{
	has:
	{
		// fields
		id: {is: "ro", init: null},
		columns: {is: "ro", init: null}
	},

	before:
	{
		initialize: function(id)
		{
			this.id = id;
			this.columns = 
			[
				{field: "name", title: "Name"}, 
				{field: "value",title: "Value"}
			];
		}
	},

	methods:
	{
		SetSource : function(source)
		{
			$("#" + this.id).empty();
			$("#" + this.id).kendoGrid(
			{
				dataSource: { data: source },
				sortable: true,
				columns: this.columns
			});
		},

		GetSource: function(tableId) 
		{
			return $("#" + this.id).data("kendoGrid").dataSource.data;
		}
	}
});